package com.ice.common.model;


import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * @author waitmoon
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class Pair<K, V> implements Serializable {
    private K key;

    public K getKey() {
        return key;
    }

    private V value;

    @Override
    public String toString() {
        return key + "=" + value;
    }

    @Override
    public int hashCode() {
        return key.hashCode() * 13 + (value == null ? 0 : value.hashCode());
    }
}

